package com.moli.iov.down.command.design.command.param.query.impl;

import com.moli.iov.down.command.codec.decode.bean.extend.QueryResExtendBean;
import com.moli.iov.down.command.design.command.param.query.ParamQueryCommand;
import com.moli.iov.util.ByteArrayUtil;

/**
 * <p>
 * 实时数据上报频率 解析
 * </p>
 *
 * @author: zql
 * @Date: 2019/4/26 14:03
 */
public class DataFrequencyCommand implements ParamQueryCommand {

    /**
     * 实时数据上报频率 解析
     * @param queryResExtendBean
     * @param value
     * @return
     */
    @Override
    public QueryResExtendBean execute(QueryResExtendBean queryResExtendBean, byte[] value) {
        queryResExtendBean.setValue(String.valueOf(ByteArrayUtil.toInt(value)));
        return queryResExtendBean;
    }
}
